#include "buddy.h"

#include <QString>

Buddy::Buddy(QString bareJid)
    : m_bareJid(bareJid), m_type(NotSet)
{
}

Buddy::Buddy(QString bareJid, Buddy::SubscriptionType type)
    : m_bareJid(bareJid), m_type(type)
{
}

Buddy::Buddy(QString bareJid, Buddy::SubscriptionType type, QSet<QString> groups)
    : m_bareJid(bareJid), m_groups(groups), m_type(type)
{
}

Buddy::Buddy(QString bareJid, Buddy::SubscriptionType type, QSet<QString>groups, QString name)
    : m_bareJid(bareJid),  m_name(name), m_groups(groups), m_type(type)
{
}

Buddy::SubscriptionType Buddy::subscriptionType()
{
    return m_type;
}

QString Buddy::bareJid()
{
    return m_bareJid;
}

QSet<QString> Buddy::groups()
{
    return m_groups;
}

QString Buddy::name()
{
    return m_name;
}

QString Buddy::subscriptionStatus()
{
    return m_subscriptionStatus;
}

void Buddy::setSubscriptionType(Buddy::SubscriptionType type)
{
    m_type = type;
}

void Buddy::setBareJid(QString bareJid)
{
    m_bareJid = bareJid;
}

void Buddy::setGroups(QSet<QString> groups)
{
    m_groups = groups;
}

void Buddy::setName(QString name)
{
    m_name = name;
}

void Buddy::setSubscriptionStatus(QString status)
{
    m_subscriptionStatus = status;
}
